package com.tukez.tmdb.model
import org.joda.time.DateTime
import org.joda.time.LocalDate
import org.joda.time.Duration

case class Movie(popularity: Int,
                 translated: Boolean,
                 adult: Boolean,
                 language: String,
                 original_name: String,
                 name: String,
                 movie_type: String,
                 id: Long,
                 url: String,
                 votes: Long,
                 rating: Double,
                 overview: String,
                 released: LocalDate,
                 posters: List[Image],
                 backdrops: List[Image],
                 version: Long,
                 last_modified_at: DateTime,
                 opt: MovieOptional,
                 details: Option[MovieDetails])

case class MovieOptional(score: Option[Double],
                         alternative_name: Option[String],
                         imdb_id: Option[String],
                         certification: Option[String],
                         runtime: Option[Duration])

case class MovieDetails(status: String,
                        tagline: String,
                        keywords: List[String],
                        budget: Long,
                        revenue: Long,
                        homepage: String,
                        trailer: String,
                        genres: List[Genre],
                        studios: List[Studio],
                        languages_spoken: List[Language],
                        countries: List[Country],
                        cast: List[CastMember])

case class Genre(name: String,
                 id: Long,
                 url: String)

case class Studio(url: String,
                  name: String,
                  id: Long)

case class Language(code: String,
                    name: String,
                    native_name: String)

case class Country(code: String,
                   name: String,
                   url: String)

case class CastMember(name: String,
                      job: String,
                      department: String,
                      character: String,
                      id: Long,
                      order: Int,
                      cast_id: Long,
                      url: String,
                      profile: String)